home *** CD-ROM | disk | FTP | other *** search
/ Game Cracker (Expanded Edition) / Game Cracker (Expanded Edition).iso / cracks / SV_HC4X4.ZIP / Hardcore 4x4.txt < prev    next >
Encoding:
Text File  |  1998-09-13  |  9.0 KB  |  187 lines

  1.  
  2. Free Information Xchange '98 presents:
  3.  
  4. Hardcore 4x4 - CD crack by Static Vengeance - Aug 19, 1998
  5.  
  6. Requirements:
  7. Hex editor and full game install
  8. W32Dasm if you wish to follow along
  9.  
  10.     Hardcore 4x4 is touted as "4x4 off-road racing at its roughest"  Also this program from Gremlin
  11. has built in support for PowerVR and 3Dfx cards.  As such I thought I would try the game out.
  12.     Also I was hoping for some type of CD check so I had another type of "game" to play.  This way I
  13. could also write up another CD cracking tutorial for you to read.  The fact that you're reading this means
  14. I found a CD check and found a way around it as well.
  15.     The first thing I did was to install the game and run it without the CD.  Right away the game
  16. came up and asked for the CD.  However this wasn't done through a simple Windows 95 pop-up dialog box,
  17. instead there was a graphics that popped up from within the game.  This means if you disassemble the
  18. program with W32Dasm you cannot just search for something like "Please insert..." or other simular dialogs.
  19. So the next best method is to use the text search function and search for GetDriveTypeA witch is a
  20. KERNEL32.dll call often used in CD checks.  If you do this you will eventualy find this routine:
  21.  
  22. * Referenced by a CALL at Addresses:
  23. |:004477A5   , :00450CF1   , :0045A486   , :0045A50A   , :0045D8DB   <-- Called from five locations
  24. |
  25. :0045D7A0 53                      push ebx
  26. :0045D7A1 51                      push ecx
  27. :0045D7A2 52                      push edx
  28. :0045D7A3 56                      push esi
  29. :0045D7A4 57                      push edi
  30. :0045D7A5 55                      push ebp
  31. :0045D7A6 83EC08                  sub esp, 00000008
  32. :0045D7A9 31D2                    xor edx, edx                   <-- Zero out edx
  33. :0045D7AB 31DB                    xor ebx, ebx                   <-- ebx is used for CD check count
  34. :0045D7AD 8915F8926200            mov dword ptr [006292F8], edx  <-- Force a fail value in CD check flag
  35.  
  36. * Reference To: KERNEL32.GetLogicalDrives, Ord:000Eh             <-- Often used in CD checks
  37.                                   |
  38. :0045D7B3 2EFF1550046500          Call dword ptr cs:[00650450]
  39. :0045D7BA 89C6                    mov esi, eax
  40. :0045D7BC BFFC926200              mov edi, 006292FC
  41. :0045D7C1 BD01000000              mov ebp, 00000001              <-- Preload pass value in ebp
  42. :0045D7C6 EB17                    jmp 0045D7DF                   <-- Jump over the deleting of dummy file
  43.  
  44. * Referenced by a (U)nconditional or (C)onditional Jump at Address:
  45. |:0045D868(C)
  46. |
  47. :0045D7C8 E81AAD0000              call 004684E7
  48. :0045D7CD 57                      push edi
  49.  
  50. * Reference To: KERNEL32.DeleteFileA, Ord:0005h              <-- Delete the "gdv\dummy.txt" file
  51.                                   |
  52. :0045D7CE 2EFF152C046500          Call dword ptr cs:[0065042C]
  53.  
  54. * Referenced by a (U)nconditional or (C)onditional Jump at Addresses:
  55. |:0045D7EA(C), :0045D812(C), :0045D81B(C), :0045D840(C), :0045D874(U)
  56. |
  57. :0045D7D5 43                      inc ebx                    <-- Increase CD check count
  58. :0045D7D6 83FB20                  cmp ebx, 00000020          <-- Min number of tries for CD check
  59. :0045D7D9 0F8D9A000000            jnl 0045D879               <-- Take this jump to exit
  60.  
  61. * Referenced by a (U)nconditional or (C)onditional Jump at Address:
  62. |:0045D7C6(U)
  63. |
  64. :0045D7DF B801000000              mov eax, 00000001
  65. :0045D7E4 88D9                    mov cl, bl
  66. :0045D7E6 D3E0                    shl eax, cl
  67. :0045D7E8 85C6                    test esi, eax
  68. :0045D7EA 74E9                    je 0045D7D5
  69.  
  70. * Possible StringData Ref from Data Obj ->"A:\"               <-- Look for "A:\" or "C:\"
  71.                                   |
  72. :0045D7EC 68BF214800              push 004821BF
  73. :0045D7F1 8D442404                lea eax, dword ptr [esp+04]
  74. :0045D7F5 50                      push eax
  75. :0045D7F6 E8DE980000              call 004670D9
  76. :0045D7FB 88D8                    mov al, bl
  77. :0045D7FD 83C408                  add esp, 00000008
  78. :0045D800 0441                    add al, 41
  79. :0045D802 880424                  mov byte ptr [esp], al
  80. :0045D805 89E0                    mov eax, esp
  81. :0045D807 50                      push eax
  82.  
  83. * Reference To: KERNEL32.GetDriveTypeA, Ord:000Bh                    <-- Commonly used in CD checks
  84.                                   |
  85. :0045D808 2EFF1544046500          Call dword ptr cs:[00650444]
  86. :0045D80F 83F805                  cmp eax, 00000005                  <-- 05 is the value for a CD rom drive
  87. :0045D812 75C1                    jne 0045D7D5                       <-- No CD rom drive them exit
  88. :0045D814 833DF892620000          cmp dword ptr [006292F8], 00000000 <-- Compare zero against CD check flag
  89. :0045D81B 75B8                    jne 0045D7D5
  90.  
  91. * Possible StringData Ref from Data Obj ->"gdv\finalds.gdv"          <-- File to check for on the CD
  92.                                   |
  93. :0045D81D 68C3214800              push 004821C3
  94. :0045D822 8D442404                lea eax, dword ptr [esp+04]
  95. :0045D826 50                      push eax
  96.  
  97. * Possible StringData Ref from Data Obj ->"%s%s"
  98.                                   |
  99. :0045D827 68D3214800              push 004821D3
  100. :0045D82C 57                      push edi
  101. :0045D82D E8A7980000              call 004670D9
  102. :0045D832 83C410                  add esp, 00000010
  103. :0045D835 57                      push edi
  104.  
  105. * Reference To: KERNEL32.GetFileAttributesA, Ord:000Ch
  106.                                   |
  107. :0045D836 2EFF1548046500          Call dword ptr cs:[00650448]
  108. :0045D83D 83F8FF                  cmp eax, FFFFFFFF
  109. :0045D840 7493                    je 0045D7D5
  110.  
  111. * Possible StringData Ref from Data Obj ->"gdv\dummy.txt"        <-- Make a file on the "CD"
  112.                                   |
  113. :0045D842 68D8214800              push 004821D8
  114. :0045D847 8D442404                lea eax, dword ptr [esp+04]
  115. :0045D84B 50                      push eax
  116.  
  117. * Possible StringData Ref from Data Obj ->"%s%s"
  118.                                   |
  119. :0045D84C 68E6214800              push 004821E6
  120. :0045D851 57                      push edi
  121. :0045D852 E882980000              call 004670D9
  122. :0045D857 83C410                  add esp, 00000010
  123.  
  124. * Possible StringData Ref from Data Obj ->"w"                   <-- Try to write to the CD?
  125.                                   |
  126. :0045D85A BAEB214800              mov edx, 004821EB
  127. :0045D85F 89F8                    mov eax, edi
  128. :0045D861 E895AB0000              call 004683FB
  129. :0045D866 85C0                    test eax, eax
  130. :0045D868 0F855AFFFFFF            jne 0045D7C8                  <-- Take this jump to delete the dummy file
  131. :0045D86E 892DF8926200            mov dword ptr [006292F8], ebp <-- Store pass value in CD check flag
  132. :0045D874 E95CFFFFFF              jmp 0045D7D5                  <-- Increase CD check count
  133.  
  134. * Referenced by a (U)nconditional or (C)onditional Jump at Address:
  135. |:0045D7D9(C)
  136. |
  137. :0045D879 A1F8926200              mov eax, dword ptr [006292F8] <-- Load the pass/fail flag
  138. :0045D87E 83C408                  add esp, 00000008             <-- Get here with eax=01 for passed check
  139. :0045D881 5D                      pop ebp
  140. :0045D882 5F                      pop edi
  141. :0045D883 5E                      pop esi
  142. :0045D884 5A                      pop edx
  143. :0045D885 59                      pop ecx
  144. :0045D886 5B                      pop ebx
  145. :0045D887 C3                      ret         <-- Return to the caller:  eax=01 for pass or eax=00 for fail
  146.  
  147.  
  148. :0045D888 0000000000000000        BYTE  8 DUP(0)
  149.  
  150.     A simple way to bypass the CD is to load eax with 00000001 and jump down to 45D87E.  This is easy
  151. to do and can be implemented at 45D7BC.  Change the mov edi, 006292FC to mov eax, 00000001 and then change
  152. the mov ebp, 00000001 at 45D7C1 to jmp 0045D881.  Now when run, the CD check will do the KERNEL32 call
  153. GetLogicalDrives and then load a pass value in eax and jump down to the return code.  This way all five
  154. known calls (and any others) will return with the correct value for a passed CD check.  To make this crack
  155. simply make the following edits:
  156.  
  157. Edit 4x4.exe at offset 318,396
  158. ================================
  159. Search for: BF FC 92 62 00 BD 01
  160. Change to : B8 01 00 00 00 E9 B8
  161.  
  162.     Or, if you like, you can kill all five calls to the CD check (which is the method I prefer) with
  163. the following edits:
  164.  
  165. Edit 4x4.exe
  166. =============================================
  167. Search for: E8 F6 5F 01 00  at offset 228,261
  168. Change to : B8 01 00 00 00
  169.  
  170. Search for: E8 AA CA 00 00  at offset 266,481
  171. Change to : B8 01 00 00 00
  172.  
  173. Search for: E8 15 33 00 00  at offset 305,286
  174. Change to : B8 01 00 00 00
  175.  
  176. Search for: E8 91 32 00 00  at offset 305,418
  177. Change to : B8 01 00 00 00
  178.  
  179. Search for: E8 C0 FE FF FF  at offset 318,683
  180. Change to : B8 01 00 00 00
  181.  
  182.     There you have two different ways to crack the same program.  You now have another example of how
  183. to remove (or bypass) a CD check.  I hope you have learned something from my efforts with Hardcare 4x4 and
  184. my other tutorials.
  185.  
  186. Static Vengeance
  187.